package com.genexususa.eo.bing.test.add;

import com.genexususa.eo.bing.connection.GoalManager;
import com.genexususa.eo.bing.test.TestUtil;

public class ConsumeAddGoals {
    public static void main(String[] args) {
        TestUtil testUtil = new TestUtil();
        String goalsXML =   "<Bing_GoalCollection xmlns=\"http://schemas.datacontract.org/2004/07/Microsoft.AdCenter.Advertiser.CampaignManagement.Api.DataContracts\">\n" +
                                "\t<Goal xmlns=\"http://schemas.datacontract.org/2004/07/Microsoft.AdCenter.Advertiser.CampaignManagement.Api.DataContracts\">\n" +
                                    "\t\t<CostModelCollection>\n" +
                                        "\t\t\t<CostModel>Shipped</CostModel>\n" +
                                        "\t\t\t<CostModel>Taxed</CostModel>\n" +
                                    "\t\t</CostModelCollection>\n" +
                                    "\t\t<DaysApplicableForConversion>Fifteen</DaysApplicableForConversion>\n" +
                                    "\t\t<GxGoalId>6065415489</GxGoalId>\n" +
                                    "\t\t<Name>Name del 1 Goal</Name>\n" +
                                    "\t\t<RevenueModel>\n" +
                                        "\t\t\t<ConstantRevenueValue>51081.45</ConstantRevenueValue>\n" +
                                        "\t\t\t<Type>Constant</Type>\n" +
                                    "\t\t</RevenueModel>\n" +
                                    "\t\t<StepCollection>\n" +
                                        "\t\t\t<Step>\n" +
                                            "\t\t\t\t<GxStepId>109460465</GxStepId>\n" +
                                            "\t\t\t\t<Name>Step Name 11</Name>\n" +
                                            "\t\t\t\t<PositionNumber>5</PositionNumber>\n" +
                                            "\t\t\t\t<Script>Step Script 11</Script>\n" +
                                            "\t\t\t\t<Type>Lead</Type>\n" +
                                        "\t\t\t</Step>\n" +
                                        "\t\t\t<Step>\n" +
                                            "\t\t\t\t<GxStepId>109460466</GxStepId>\n" +
                                            "\t\t\t\t<Name>Step Name 12</Name>\n" +
                                            "\t\t\t\t<PositionNumber>6</PositionNumber>\n" +
                                            "\t\t\t\t<Script>Step Script 12</Script>\n" +
                                            "\t\t\t\t<Type>Conversion</Type>\n" +
                                        "\t\t\t</Step>\n" +
                                    "\t\t</StepCollection>\n" +
                                    "\t\t<YEventId>45640651</YEventId>\n" +
                                "\t</Goal>\n" +
                                "\t<Goal xmlns=\"http://schemas.datacontract.org/2004/07/Microsoft.AdCenter.Advertiser.CampaignManagement.Api.DataContracts\">\n" +
                                    "\t\t<CostModelCollection>\n" +
                                        "\t\t\t<CostModel>Shipped</CostModel>\n" +
                                        "\t\t\t<CostModel>NonAdvertising</CostModel>\n" +
                                    "\t\t</CostModelCollection>\n" +
                                    "\t\t<DaysApplicableForConversion>FortyFive</DaysApplicableForConversion>\n" +
                                    "\t\t<GxGoalId>6065415490</GxGoalId>\n" +
                                    "\t\t<Name>Name del 2 Goal</Name>\n" +
                                    "\t\t<RevenueModel>\n" +
                                        "\t\t\t<Type>None</Type>\n" +
                                    "\t\t</RevenueModel>\n" +
                                    "\t\t<StepCollection>\n" +
                                        "\t\t\t<Step>\n" +
                                            "\t\t\t\t<GxStepId>109460467</GxStepId>\n" +
                                            "\t\t\t\t<Name>Step Name 21</Name>\n" +
                                            "\t\t\t\t<PositionNumber>7</PositionNumber>\n" +
                                            "\t\t\t\t<Script>Step Script 21</Script>\n" +
                                            "\t\t\t\t<Type>Prospect</Type>\n" +
                                        "\t\t\t</Step>\n" +
                                        "\t\t\t<Step>\n" +
                                            "\t\t\t\t<GxStepId>109460468</GxStepId>\n" +
                                            "\t\t\t\t<Name>Step Name 22</Name>\n" +
                                            "\t\t\t\t<PositionNumber>8</PositionNumber>\n" +
                                            "\t\t\t\t<Script>Step Script 22</Script>\n" +
                                            "\t\t\t\t<Type>Conversion</Type>\n" +
                                        "\t\t\t</Step>\n" +
                                    "\t\t</StepCollection>\n" +
                                    "\t\t<YEventId>45640652</YEventId>\n" +
                                "\t</Goal>\n" +
                            "</Bing_GoalCollection>\n";
        GoalManager resource = new GoalManager();
        System.out.println("Consuming AddGoals.....");
        String userName = testUtil.userName;
        String password = testUtil.password;
        String developerToken = testUtil.developerToken;
        long customerId = testUtil.customerId;
        long customerAccountId = testUtil.customerAccountId;
        String applicationId = testUtil.applicationId;
        long accountId = testUtil.accountId1;
       // String result = resource.addGoals(userName, password, developerToken, customerId, customerAccountId, applicationId, accountId, goalsXML);
       // System.out.println("Result:\n" + result);
    }
}
